<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.train.${module}.mapper.${Domain}Mapper">

    <resultMap type="com.train.system.po.${Domain}PO" id="${Domain}Map">
    <#list fieldList as field>
        <#if field.javaType == "Long">
        <result property="${field.nameHump}" column="${field.name}" jdbcType="INTEGER"/>
        </#if>
        <#if field.javaType == "Integer">
        <result property="${field.nameHump}" column="${field.name}" jdbcType="INTEGER"/>
        </#if>
        <#if field.javaType == "BigDecimal">
        <result property="${field.nameHump}" column="${field.name}" jdbcType="DECIMAL"/>
        </#if>
        <#if field.javaType=='Date'>
        <result property="${field.nameHump}" column="${field.name}" jdbcType="VARCHAR"/>
        </#if>
        <#if field.javaType=='Boolean'>
        <result property="${field.nameHump}" column="${field.name}" jdbcType="BOOLEAN"/>
        </#if>
        <#if field.javaType=='String'>
        <result property="${field.nameHump}" column="${field.name}" jdbcType="VARCHAR"/>
        </#if>
    </#list>
    </resultMap>

    <sql id="Base_Column_List">
        <#list fieldList as field>
            ${field.name}<#if field_has_next>,</#if>
        </#list>
    </sql>

</mapper>